<?php
require_once("vcl/vcl.inc.php");
require_once("lib/db_connection.php");
//Includes
use_unit("forms.inc.php");
use_unit("extctrls.inc.php");
use_unit("stdctrls.inc.php");

//Class definition
class Fuel_Delete extends Page
{
       public $hiddenFuel = null;
       public $hiddenVeh = null;
       function Fuel_DeleteCreate($sender, $params)
       {
       $veh=$_GET['veh'];
       $fuel=$_GET['fuel'];
       $this->hiddenVeh->setValue($veh);
       $this->hiddenFuel->setValue($fuel);

       $result = mysql_query("delete from veh_fuel_tbl where vehicle_id='".$this->hiddenVeh->getValue()."' and fuel_id='".$this->hiddenFuel->getValue()."'");
       redirect('veh_fuel_list.php?veh='.$this->hiddenVeh->getValue().'&fuel='.$this->hiddenFuel->getValue());


       }

}

global $application;

global $Fuel_Delete;

//Creates the form
$Fuel_Delete=new Fuel_Delete($application);

//Read from resource file
$Fuel_Delete->loadResource(__FILE__);

//Shows the form
$Fuel_Delete->show();

?>